#include <iostream>

class Base
{
public:
    Base(int a):a(a){}
protected:
    int a;
};

class Base1:public Base
{
public:
    Base1(int a,int b):Base(a),b(b){}

protected:
    int b;
};

class Base2:virtual public Base
{
public:
    Base2(int a,int c):Base(a),c(c){}
protected:
    int c;
};

//虚继承
//单继承+组合 -> 多继承
class Derived:public Base1
{
public:
    Derived(int a,int b,int c)
    {
        this->a = a;
    }
private:
    Base2 b;
};